<html>
<body>
    <table border="1">
        <tr>
            <td></td>
            <td>
                <a href="?sort=cacheName">CacheName</a>
            </td>
            <td title="localDiskHitCount">
                <a href="?sort=localDiskHitCount">DiskHit</a>
            </td>
            <td title="localHeapHit">
                <a href="?sort=localHeapHitCount">HeapHit</a>
            </td>
            <td title="cacheHit">
                <a href="?sort=cacheHitCount">Hit</a>
            </td>
            <!--  -->
            <td title="cacheMiss">
                <a href="?sort=cacheMissCount">Miss</a>
            </td>
            <td title="cacheMissExpired">
                <a href="?sort=cacheMissExpiredCount">Expired</a>
            </td>
            <td title="cacheMissExpired/cacheHit">
                <a href="?sort=missExpiredRatio">%</a>
            </td>
            <td title="cacheMissNotFound">
                <a href="?sort=cacheMissNotFoundCount">NotFound</a>
            </td>
            <td title="cacheMissNotFound/cacheHit">
                <a href="?sort=missNotFoundRatio">%</a>
            </td>
            <!--  -->
            <td title="cachePut">
                <a href="?sort=cachePutCount">Put</a>
            </td>
            <td title="cachePutAdded">
                <a href="?sort=cachePutAddedCount">Added</a>
            </td>
            <!--  -->
            <td title="cacheRemove">
                <a href="?sort=cacheRemoveCount">Remove</a>
            </td>
            <td title="cacheEvicted">
                <a href="?sort=cacheEvictedCount">Evicted</a>
            </td>
            <td title="cacheExpired">
                <a href="?sort=cacheExpiredCount">Expired</a>
            </td>
            <!--  -->
            <td title="TimeToLiveSeconds">
                <a href="?sort=timeToLiveSeconds">TTL</a>
            </td>
            <td title="TimeToIdleSeconds">
                <a href="?sort=timeToIdleSeconds">TTI</a>
            </td>
            <td title="MaxEntriesLocalHeap">
                <a href="?sort=maxEntriesLocalHeap">HeapMax</a>
            </td>
            <td title="MaxEntriesLocalHeap">
                <a href="?sort=maxEntriesLocalDisk">DiskMax</a>
            </td>
            <td>
                <a href="?sort=keyCount">Keys</a>
            </td>
            <td>操作</td>
        </tr>

        <#assign _sort>${(RequestParameters["sort"])!}</#assign>
        <#if !(_sort??) || (_sort?length lt 1)> 
            <#assign _sort>cacheName</#assign> 
        </#if>

        <#list cacheStatList?sort_by(_sort) as cacheStat>
        <tr>
            <td>
                <#if cacheStat.configGraph > 
                    <a target="_blank" href="line-graph?type=CACHE&key=${cacheStat.cacheName}"><b>${cacheStat_index+1}</b></a>
                <#else>
                    ${cacheStat_index+1}
                </#if>
            </td>

            <td>${cacheStat.cacheName}</td>
            <td>${cacheStat.localDiskHitCount?c}</td>
            <td>${cacheStat.localHeapHitCount?c}</td>
            <td>${cacheStat.cacheHitCount?c}</td>
            <!--  -->
            <td>${cacheStat.cacheMissCount?c}</td>
            <td>${cacheStat.cacheMissExpiredCount?c}</td>
            <td>${cacheStat.missExpiredRatio!}</td>
            <td>${cacheStat.cacheMissNotFoundCount?c}</td>
            <td>${cacheStat.missNotFoundRatio!}</td>
            <!--  -->
            <td>${cacheStat.cachePutCount?c}</td>
            <td>${cacheStat.cachePutAddedCount?c}</td>
            <!--  -->
            <td>${cacheStat.cacheRemoveCount?c}</td>
            <td>${cacheStat.cacheEvictedCount?c}</td>
            <td>${cacheStat.cacheExpiredCount?c}</td>
            <!--  -->
            <td>${cacheStat.timeToLiveSeconds?c}</td>
            <td>${cacheStat.timeToIdleSeconds?c}</td>
            <td>${cacheStat.maxEntriesLocalHeap?c}</td>
            <td>${cacheStat.maxEntriesLocalDisk?c}</td>
            <!--  -->
            <td>${cacheStat.keyCount?c}</td>

            <td title="清除缓存">
                <a target="_blank" href="ehcache-statistics-clear-${cacheStat.cacheName}">Clear</a>
            </td>
        </tr>
        </#list>
    </table>
</body>
</html>